1. The Field of the Invention
The present invention generally relates to reliable messaging systems. More particularly, the present invention provides systems, methods, and computer program products for improving availability and scalability for reliable two-party messaging systems, such that the improvements are transparent to the application.
2. Background and Relevant Art
Messaging systems have become an increasingly popular way to communicate. These communication systems range from e-mail systems to secured transactions, from chat rooms to various web services such as internet shopping. These systems and applications have widely-varying requirements regarding messaging reliability, security, performance, availability and scalability. Existing systems offer partial solutions that address specific, limited combinations of the more general requirements.
Traditional prior art messaging systems typically offer limited flexibility in terms of the assurances (e.g., exactly-once delivery), message exchange patterns (e.g., one-way versus request/response or full duplex), and messaging interface semantics (e.g., transactional message buffering). Each of these messaging systems typically address a limited set of scalability and availability requirements, and either offer few options for extending the system to increase overall scalability or availability, or require extensive application involvement.
For example, consider the following two-party communication models. Datagram systems typically offer one-way, session-less message exchange, with fire and forget reliability, and offer little direct support for scalability and availability. These systems offer developers the ultimate freedom and flexibility to build everything themselves.
TCP provides full-duplex, session-oriented communication. It has a richer, but fixed set of delivery assurances (exactly-once, in-order, delivery of bytes). Connection state is maintained in volatile in-memory data structures, and connections cannot survive system and process failures, and many network failures, limiting availability.
RCP provides a half-duplex exchange pattern; some systems limit this to single request/response interactions and some provide for conversational sessions. In either case, endpoint state is typically maintained in-memory and hence has availability limitations similar to TCP. While the session-less request/response systems can sometimes achieve great scalability (consider HTTP-based web farms), these typically do not provide at-most-once request processing, hence limiting their use to idempotent requests. Session based RPC systems can provide request retry with at-most-once processing allowing for some increased availability. In some cases, the underlying transport connections are managed by the runtime allowing multiplexing with some increase in scalability.
Finally, message queuing systems generally provide exactly-once delivery semantics. Unlike the datagram, TCP and RPC models, queues impose buffering between the two communicating parties, allowing for additional connectivity and scheduling flexibility. Many message queuing systems provide durable state storage affording additional availability by tolerating process and system failures. Some queuing systems also have transaction support; this model can increase reliability and availability by automatically undoing partial work and enabling automatic retry processing. These systems generally impose limited storage options, such as requiring the use of a proprietary, durable store, and have transport dependencies that limit network configuration.
Accordingly, there exists a need for a messaging system that allows increased flexibility to adapt applications to special runtime conditions and requirements, as long as the application-mandated assurances are met. Further, there exists a need for a messaging system with the aforementioned flexibility that can be used to tailor application availability and scalability to the needs of a specific deployment, in a manner transparent to the application program.